package com.byxy.ssm.controller;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;

import com.byxy.ssm.service.TipService;

@Controller
public class MainController {

	@Resource 
	private TipService tipService;
	@GetMapping("/toMainPage.do")
	public String mian(Model model) {
		model.addAttribute("mains",tipService.findAll());
		return "main";
	}
}
